package thread.sington;

public class DCLSinglton1 {
  private static int value;
  private static volatile DCLSinglton1 dclSinglton1;

  private DCLSinglton1(int value) {
    value = value;
  }

  public DCLSinglton1 getInstance(){
    if (dclSinglton1 == null) {
      synchronized (this){
        if (dclSinglton1 == null){
          dclSinglton1 = new DCLSinglton1(value);
        }
      }
    }
    return dclSinglton1;
  }
}
